<?php

namespace common\models\WxFollowLog;

use Yii;

/**
 * This is the model class for table "wx_follow_log".
 *
 * @property string $id
 * @property string $wx_public_id
 * @property string $created_date
 * @property string $created_ym
 * @property string $wechat_open_id 微信 open id
 */
class WxFollowLogBase extends \common\models\CommonModel\CommonModel
{
    /**
     * {@inheritdoc}
     */
    public static function tableName()
    {
        return 'wx_follow_log';
    }

    /**
     * {@inheritdoc}
     */
    public function rules()
    {
        return [
            [['wx_public_id', 'created_date', 'created_ym'], 'required'],
            [['wx_public_id'], 'integer'],
            [['created_date'], 'safe'],
            [['created_ym'], 'string', 'max' => 7],
            [['wechat_open_id'], 'string', 'max' => 80],
            [['wechat_open_id'], 'unique'],
        ];
    }

    /**
     * {@inheritdoc}
     */
    public function attributeLabels()
    {
        return [
            'id' => 'ID',
            'wx_public_id' => 'Wx Public ID',
            'created_date' => 'Created Date',
            'created_ym' => 'Created Ym',
            'wechat_open_id' => 'Wechat Open ID',
        ];
    }
}
